def factorial(n):
    if n == 0 or n == 1:
        return 1
    return n * factorial(n - 1)

n = int(input("请输入一个整数: "))
print(f"{n}的阶乘是{factorial(n)}")